package com.zjq.authoritysystem.vo.result;

import java.io.Serializable;

/**
 * @author Administrator
 */

public enum ResultCode implements Serializable {

    SUCCESS(200, "success"),

    WEBSOCKET_SUCCESS(220, "WebSocket 成功"),

    WEBSOCKET_RETRY_SUCCESS(221, "WebSocket 重试成功"),

    TIP_ERROR(401, "tip error"),

    TOKEN_ERROR(405, "token 异常"),

    PARAM_ERROR(400, "参数错误"),

    PARAMETER_VERIFY_ERROR(403, "参数校验错误"),

    ERROR(500, "失败"),

    NO_LOGIN(600, "未登录"),

    NO_AUTH(700, "未授权");

    private Integer code;
    private String message;

    ResultCode() {
    }

    ResultCode(Integer code, String msg) {
        this.code = code;
        this.message = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return message;
    }

    public void setMsg(String msg) {
        this.message = msg;
    }
}
